version "14.1-20140302.1 [builder]";
dynamic-profiles {
    IP-DHCP-PROFILE-1 {
        interfaces {
            "$junos-interface-ifd-name" {
                unit "$junos-underlying-interface-unit";
            }
        }
    }
}
system {
    host-name vmx-20;
    time-zone GMT+4;
    root-authentication {
        encrypted-password "$1$r1mevasJ$eSMgu20mBd7qe91Y9Hc3L/"; ## SECRET-DATA
    }
    name-server {
        8.8.4.4;
    }
    dynamic-profile-options {
        versioning;
    }
    login {
        user warrior {
            uid 2000;
            class super-user;
            authentication {
                encrypted-password "$1$CP6.Oezz$vcaU1R2xnijIFVcP66uP9."; ## SECRET-DATA
            }
        }
    }
    services {
        telnet;
        dhcp-local-server {
            pool-match-order {
                ip-address-first;
            }
            authentication {
                password 123;
                username-include {
                    mac-address;
                }
            }
            dynamic-profile IP-DHCP-PROFILE-1;
            group 1 {
                interface ge-0/0/2.10;
            }
        }
    }
    syslog {
        user * {
            any emergency;
        }
        file messages {
            any notice;
            authorization info;
            interactive-commands none;
        }
        file interactive-commands {
            interactive-commands any;
        }
    }
}
chassis {
    network-services enhanced-ip;
}
access-profile Access-Profile-1;
interfaces {
    ge-0/0/1 {
        description "-- uplink & OOB";
        mtu 2000;
        gigether-options {
            no-flow-control;
        }
        unit 0 {
            family inet {
                address 192.168.64.20/24;
            }
        }
    }
    ge-0/0/2 {
        description "-- subscriber access";
        flexible-vlan-tagging;
        mtu 2000;
        encapsulation flexible-ethernet-services;
        gigether-options {
            no-flow-control;
        }
        unit 10 {
            vlan-id 10;
            family inet {
                address 192.168.0.1/24;
            }
        }
    }
    ge-0/0/3 {
        description "-- FREEBSD Server";
        mtu 2000;
        gigether-options {
            no-flow-control;
        }
        unit 0 {
            family inet {
                address 192.168.99.1/24;
            }
        }
    }
    lo0 {
        unit 0 {
            family inet {
                address 1.1.1.20/32 {
                    primary;
                    preferred;
                }
            }
        }
    }
}
routing-options {
    static {
        route 0.0.0.0/0 {
            next-hop 192.168.64.2;
            no-readvertise;
        }
    }
    router-id 1.1.1.20;
    autonomous-system 20;
    forwarding-table {
        export lb;
    }
}
policy-options {
    policy-statement lb {
        then {
            load-balance per-packet;
        }
    }
}
access {
    profile Access-Profile-1 {
        accounting-order radius;
        authentication-order radius;
        radius {
            authentication-server 192.168.99.2;
            accounting-server 192.168.99.2;
            options {
                nas-port-id-delimiter :;
                calling-station-id-delimiter :;
                calling-station-id-format {
                    nas-identifier;
                    interface-description;
                }
                accounting-session-id-format decimal;
                coa-dynamic-variable-validation;
            }
        }
        radius-server {
            192.168.99.2 {
                port 1812;
                accounting-port 1813;
                secret "$9$45Zi.Qz6AtOQFCu0Byr"; ## SECRET-DATA
                timeout 5;
                retry 3;
                max-outstanding-requests 200;
            }
        }
        accounting {
            order radius;
            immediate-update;
            coa-immediate-update;
            update-interval 10;
            statistics volume-time;
        }
    }
    address-assignment {
        pool 1 {
            family inet {
                network 192.168.0.0/24;
                range R1 {
                    low 192.168.0.101;
                    high 192.168.0.200;
                }
                dhcp-attributes {
                    maximum-lease-time 3600;
                    name-server {
                        8.8.4.4;
                    }
                    router {
                        192.168.0.1;
                    }
                }
            }
        }
    }
}
